#! /usr/bin/env python
# -*- coding: utf8 -*-

# #portugues@ScoutLink 2006 JOTI Bot (slbot)
# Copyright (c) 2006, ScoutLink #portugues team
# This source is released under the New BSD License. See the LICENSE file for further
# information.

# $Author$
# $Date$ 

__version__ = "$Revision$"
# $Source$

from twisted.plugin import IPlugin
from zope.interface import implements
from slbot.slbot import __break_user__
from slbot.slinterface import ISLPlugin

class SLChanHop:
    implements(IPlugin, ISLPlugin)
    
    author_name    = 'Alexandre Coster'
    author_email   = 'acoster@ScoutLink.net'
    author_webpage = 'http://acoster.net/'
    plugin_name    = 'Channel Redirector'
    plugin_version = '1.0'
    
    def register_me(self, bot):
        self.bot = bot
        bot.reg_plugin("join", self)
        self.base_chan = bot.cfg.get("chan_hop", "basename")

    def join(self, user, channel):
        if channel == self.base_chan:
            for i in range(1, self.bot.)